var genderArr = [{value:true,text:'男'},{value:false,text:'女'}];
var genderObj = {value:'true:男;false:女'};

function custom_func4StudentRemark(cellVal,cellLabel){
	if(cellVal && cellVal.length>0){
		return [true,"",""];
	}
	else{
		return [false,cellLabel+","+$.jgrid.edit.msg.required,""];
	}
}

function afterSelectRow4Student(rowData){
	//联想控件的单元格对自己赋值必须用这种方式
	$(this).val(rowData.address);
	//对其它单元格赋值
	var rowId = $('#tableStudent').jqGrid('getCurrentSelectRowId');
	$("#tableStudent").jqGrid('setCell', rowId, 'telphone', rowData.telphone,false,false,true);
	$("#tableStudent").jqGrid('setCell', rowId, 'phone', rowData.phone,false,false,true);
}
function afterEditCellFunc4Student(rowId,colName,colValue,rowIndex,colIndex){
	if (colName == 'birthday') {
		window.setTimeout(function(){
			$("#" + rowIndex + "_birthday", "#tableStudent").bind("focus click",function(){
				WdatePicker({dateFmt:'yyyy-MM-dd'})
			});
		},0);
	}
	if (colName == 'address') {
		window.setTimeout(function(){
			//给单元格的autoSelectConfig 必须以继承方式配置$.extend({},config)
			$("#" + rowIndex + "_address", "#tableStudent").autoSelect($.extend({},colAddressAutoSelectConfig)).bind("keyup",function(){
				//当表格内联想控件输入值时，同时清空其它单元格数据
				$("#tableStudent").jqGrid('setCell', rowId, 'telphone', "",false,false,true);
				$("#tableStudent").jqGrid('setCell', rowId, 'phone', "",false,false,true);
			})
		},0);
	}
}